/**
 *  Desc:   banner图管理
 *  Author: 刘玉峰
 *  Date:   2020-10-15 13:12
 */

import request from "@/utils/request";
import { removeEmptyKeys } from "@/utils/utils";


// 
export async function loadBanner() {
  return request(`/api/admin/banner`);
}

// 删除
export async function deleteBanner(id) {
  return request(`/api/admin/bannerDelete/${id}`, {
    method: "GET",
  });
}

export async function setBanner(params) {
  // params = removeEmptyKeys(params);
  return request.post("/api/admin/bannerEdit",{
    method: "POST",
    data:params
  });
}
